-
Notifications
You must be signed in to change notification settings - Fork 357
Add AI recommendation feature using GitHub username input #1344
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
@JANVISAHARAN is attempting to deploy a commit to the avdheshvarshney's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
Thank you for submitting your pull request! We'll review it as soon as possible. For further communication, join our discord server https://discord.gg/tSqtvHUJzE. |
Avdhesh-Varshney
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Refactor
server/src/servicesby taking reference from the other apis development. - No need to create
index2.jsfile. - For recommendation, Don't create route for now. Display everything in a modal.
- Implement the api functions in
/infra/apisdirectory
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Avdhesh-Varshney
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Try to reuse the same code. And in server, there is no route structure?
Next time please share me the postman api working screenshots. Along with the working prototype video of this task.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Convert this file into JSON file instead of js.
| import { fetchRepositoryLanguages } from './fetch-repository-languages.js'; | ||
| import { fetchPullRequestMetrics } from './fetch-pull-request-metrics.js'; | ||
| import { fetchIssueMetrics } from './fetch-issue-metrics.js'; | ||
| import { detectCapabilities } from './detect-capabilities.js'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All these files are not required. Try to collab them into a single file.
And move the github logic part in controllers. No need to create a separate dir of services.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to of this file just to export.
| useEffect(() => { | ||
| const fetchRecommendation = async () => { | ||
| try { | ||
| const res = await fetch("http://localhost:5000/api/recommend", { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use the created apis function instead of using fetch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Import this in navbar to make it workable.
| process.env.RESEND_API_KEY || 'dev_resend_key_abc123'; | ||
|
|
||
| // AI Configuration | ||
| export const GEMINI_API_KEY = process.env.GEMINI_API_KEY; No newline at end of file |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add some optional OR value.
process.env.GEMINI_API_KEY || 'gemini_api_key'
| ${JSON.stringify(analysisData, null, 2)} | ||
| `; | ||
|
|
||
| const response = await fetch( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use axios instead of fetch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the usecase of this file?
If not required, remove it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove it.
Pull Requests Review Criteria
Caution
PRs that fail to meet these review standards will be automatically flagged and may be rejected by maintainers.
mainCloses:
Describe the add-ons or changes you've made 📃
1)I have added a small AI recommendation features that take GitHub username of the user as input and analyze the users Github profile and repositories in every manner including the Time When they generated the issue and created the PR different repositories that they have their languages that it consist of .
2)Then all this data is going to Gemini Which I have connected through Gemini API key which gives the output in which it only states the future projects which can be made by user according to the data that has been fetched from Github.
3) In the front end after right I have added option of get recommendation which also has an iconic AI assistant which if clicked will automatically generate the recommendation.
Screenshots 📷
Note to reviewers (Optional) 📄